package com.example.demo.service.impl;

import com.example.demo.dao.OrderFormDao;
import com.example.demo.pojo.OrderForm;
import com.example.demo.service.OrderFormService;
import com.example.demo.util.GetOrderSelId;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
@Service("orderFormService")
public class OrderFormServiceImpl implements OrderFormService{
    @Resource(name="orderFormDao")
    private OrderFormDao orderFormDao;
    @Override
    public List<GetOrderSelId> getOrderFormAll() {
        return orderFormDao.getOrderFormAll();
    }


    @Override
    public int deleteByPrimaryKey(Integer orderid) {
        return orderFormDao.deleteByPrimaryKey(orderid);
    }

    @Override
    public int insert(OrderForm record) {
        return orderFormDao.insert(record);
    }

    @Override
    public int insertSelective(OrderForm record) {
        return orderFormDao.insertSelective(record);
    }

    @Override
    public OrderForm selectByPrimaryKey(Integer orderid) {
        return orderFormDao.selectByPrimaryKey(orderid);
    }

    @Override
    public int updateByPrimaryKeySelective(OrderForm record) {
        return orderFormDao.updateByPrimaryKeySelective(record);
    }

    @Override
    public int updateByPrimaryKey(OrderForm record) {
        return orderFormDao.updateByPrimaryKey(record);
    }

    @Override
    public int updateOrderStatuId(int id) {
        return orderFormDao.updateOrderStatuId(id);
    }

    @Override
    public int updateCancelled(int id) {
        return orderFormDao.updateCancelled(id);
    }

    @Override
    public int updateOrderStatuDeliverGoods(int id) {
        return orderFormDao.updateOrderStatuDeliverGoods(id);
    }

    @Override
    public int updateOrderStatuAfterSale(int id) {
        return orderFormDao.updateOrderStatuAfterSale(id);
    }

    @Override
    public List<GetOrderSelId> getOrderUserId(Integer userId) {
        return orderFormDao.getOrderUserId(userId);
    }

    @Override
    public List<GetOrderSelId> getOrderWareId(Integer wareId) {
        return orderFormDao.getOrderWareId(wareId);
    }

    @Override
    public GetOrderSelId getOrder(String order) {
        return orderFormDao.getOrder(order);
    }

    @Override
    public OrderForm getOrderNumber(String orderNumber) {
        return orderFormDao.getOrderNumber(orderNumber);
    }

    @Override
    public int updateOrderStatus(int orderStatusId, String ordernumber) {
        return orderFormDao.updateOrderStatus(orderStatusId,ordernumber);
    }


    @Override
    public OrderForm getOne(String ordernumber) {
        return orderFormDao.getOne(ordernumber);
    }


}
